Release 10.1A: OpenEdge Application Server:
Developing WebSpeed Applications
Formatting DISPLAY output
In general,
DISPLAYoutput is formatted using SpeedScript frames. These are not HTML frames, but are logical structures maintained by SpeedScript to manage its output. There are several types of SpeedScript frames you can use to stream output to the Web, and this output can be organized into still larger, multi-frame stream pages. Stream pages are not Web pages, but logical sections of a Web page containing one or more SpeedScript frames. For information on the available types of SpeedScript frames, see the Frame Phrase entry in the OpenEdge Development: Progress 4GL Reference .Keep in mind that these SpeedScript frames and the larger multi-frame stream pages are structures that WebSpeed uses to format a single Web page for a single request. They do not, in and of themselves, return as successive individual Web pages, such as appears for large result sets from a Web search engine. They merely provide a means to partition and give structure to a single Web page using
Note: Stream paging applies both toDISPLAYand other SpeedScript statements.DISPLAYandPUT({&OUT}) statement output. However, onlyDISPLAY(and SQLSELECT) statements output SpeedScript frames.You can format
DISPLAYstatement output using two mechanisms:Paging options of the OUTPUT TO "WEB" statement
The two paging options include:
To open an unnamed output stream with 25-line stream pages, you specify this:
Each stream page contains the following output ordered and organized into one to three sections, all within the number of lines specified for the stream page:
- Any content from activated SpeedScript
PAGE-TOPframes for the currentOUTPUTstream. Otherwise, the stream page begins with the second section.- Any other
DISPLAYorPUTstatement output for the currentOUTPUTstream. IfDISPLAYoutput is for a SpeedScriptDOWNframe, any column headers are printed in the following occurrences:
- At the start of an iteration block.
- At the start of the stream page or immediately after any output from
PAGE-TOPframes.If
DISPLAYoutput is for a SpeedScript frame other than aDOWNframe, the entire content from the specified frame is output for eachDISPLAYstatement.All output in the second part of the stream page continues until the line number required to start any activated
PAGE-BOTTOMframe or after the last line of the stream page, which ever comes first. IfPAGE-BOTTOMframe output is activated, the stream page continues with the third section. Otherwise, the stream page is complete.- Any content from activated SpeedScript
PAGE-BOTTOMframes for the currentOUTPUTstream until the stream page is complete.Activate SpeedScript
PAGE-TOPandPAGE-BOTTOMframes usingDISPLAYstatements. These statements do not immediately output the frames, but make them ready for output at the appropriate point in a stream page. Note also thatPUTstatements (most often coded using the WebSpeed{&OUT}preprocessor reference) can send output in the second section of a stream page. But this output is not part of any SpeedScript frames, which are used only byDISPLAYstatements.WebSpeed also provides a means to automatically separate successive stream pages in the HTML using a specified divider. This divider is specified by the
HTML-END-OF-PAGEattribute of theWEB-CONTEXTsystem handle. For more information, see the "HTML attributes of the WEB-CONTEXT handle" section.For more information on setting these options, see the "Changing output format defaults" section.
HTML attributes of the WEB-CONTEXT handle
The
WEB-CONTEXThandle provides a set of attributes to modify the formatted output in a Web page. Each attribute is a character string that contains HTML you want to add to a specified portion of SpeedScript frame and paged output. Any settings that you make to these attributes last only until the next Web request. Each request causes the agent to reset these attributes to the default values. This is true for both stateless and state-persistent Web objects.Table 4–1 describes how to use these attributes. For information on how to set and read these attributes, see the
WEB-CONTEXTHandle entry in the OpenEdge Development: Progress 4GL Reference . For information on setting new defaults for these attributes, see the "Setting HTML attribute defaults" section.
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |